1. Field of the Invention
The present invention relates generally to a switching control circuit, and more specifically to a method and apparatus for detecting a switching current of a power converter operated at continuous current mode.
2. Description of the Related Art
A power converter is used to convert an unregulated power source to a regulated voltage or current source. The power converter normally includes a transformer or a magnetic device having a primary winding and a secondary winding to provide isolation. A switching device connected with the primary winding to control energy transfer from the primary winding to the secondary winding. FIG. 1 shows a conventional power converter. A controller 50 generates a switching signal VG to regulate the output of the power converter in response to a feedback signal VFB. The feedback signal VFB is correlated to the output VO of the power converter. The switching signal VG drives a power transistor 20 for switching a transformer 10. The transformer 10 is connected to an input voltage VIN of the power converter. The energy of the transformer 10 is transferred to the output VO of the power converter through a rectifier 40 and a capacitor 45. A resistor 30 is connected serially with the power transistor 20 to generate a switching current signal VI in response to a switching current IP of the transformer 10. The switching current signal VI is coupled to the controller 50 for the control the power converter. The power converter will be operated at discontinuous current mode (DCM) when the transformer 10 is fully discharged before the start of the switching cycle. If the switching signal VG is enabled before the transformer 10 is fully discharged, the power converter will be operated at continuous current mode (CCM). A continuous current will be remained in the transformer when the power converter operated in the CCM. FIG. 2 shows a CCM waveform of the switching current IP, in which the continuous current IA represents the energy stored in the transformer 10. A ramp current IC is the energy that is further charged into the transformer 10 during the on time TON of this switching cycle T. The continuous current IA stands for a major energy transfer of the transformer 10. A voltage spike and noise are generated at the rising edge of the switching current IP. The voltage spike and noise will generate error for the sampling. The object of the present invention is to develop a method and apparatus to measure the continuous current IA and the ramp current IC of the switching current IP.